<%@ page language="java" import="java.util.*,share.security.auth.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="/tld/sys" prefix="sys"%>
<%@ taglib uri="/tld/cache" prefix="ch"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<base href="<%=basePath%>">
		<title>浏览 <sys:path file="${file}" />
		</title>
		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<link rel="stylesheet" href="css/standard.css" type="text/css" />
		<link rel="stylesheet" href="css/list.css" type="text/css" />
		<link href="css/floatDiv.css" rel="stylesheet" type="text/css" />
		<link href="css/toolbar.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="js/floatDiv.js"></script>
		<script type="text/javascript" src="js/toolbar.js"></script>
	</head>
	<body>
		<!-- ToolBar Section -->
		<jsp:include page="WEB-INF/include/ToolBar.jsp"/>
		<div id="menu">
			<img id="logo" width="64" height="64" alt="<sys:info name="name"/>"
				src="img/logo.png"/>
			<sys:code file="dir.menu.tpl" />
			<hr />
		</div>
		<div id="contain">
			<div id="path">
				<a href="files<sys:path file="${file}" type="parent"/>">返回目录</a>
				<br>
			</div>
			<div id="listContainer">
				文件名：${file.filename}
				<br>
				大 小：
				<c:if test="${file.size>=1024*1024}">
					<fmt:formatNumber value="${file.size/(1024*1024)}" pattern="#.##" /> MB
				</c:if>
				<c:if test="${file.size<1024*1024&&file.size>=1024}">
					<fmt:formatNumber value="${file.size/(1024)}" pattern="#.##" /> KB
				</c:if>
				<c:if test="${file.size<1024}">
					${file.size} Bytes
				</c:if>
				<br>
				描  述：${file.describe}<br><br>
				<a href="download<sys:path file="${file}"/>">下载</a>
			</div>
		</div>
		<!-- Footer -->
		<jsp:include page="WEB-INF/include/foot.jsp"/>
	</body>
</html>
